home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Language/OS - Multiplatform Resource Library
/
LANGUAGE OS.iso
/
glass
/
glass.lha
/
GLASS
/
dtm
/
dtm_atoms.c
< prev
next >
Wrap
Text File
|
1991-06-18
|
1KB
|
29 lines
#define one(t) (1)
#define zero(t) (0)
#define init(t) ((t<3)?0:1)
#define buf(x) (x)
#define not(x) (!(x))
#define and2(a0,a1) ((a0) && (a1))
#define and3(a0,a1,a2) ((a0) && (a1) && (a2))
#define and4(a0,a1,a2,a3) ((a0) && (a1) && (a2) && (a3))
#define and5(a0,a1,a2,a3,a4) ((a0) && (a1) && (a2) && (a3) && (a4))
#define or2(a0,a1) ((a0) || (a1))
#define or3(a0,a1,a2) ((a0) || (a1) || (a2))
#define or4(a0,a1,a2,a3) ((a0) || (a1) || (a2) || (a3))
#define or5(a0,a1,a2,a3,a4) ((a0) || (a1) || (a2) || (a3) || (a4))
#define nand2(a0,a1) (!((a0) && (a1)))
#define nand3(a0,a1,a2) (!((a0) && (a1) && (a2)))
#define nand4(a0,a1,a2,a3) (!((a0) && (a1) && (a2) && (a3)))
#define nand5(a0,a1,a2,a3,a4) (!((a0) && (a1) && (a2) && (a3) && (a4)))
#define nor2(a0,a1) (!((a0) || (a1)))
#define nor3(a0,a1,a2) (!((a0) || (a1) || (a2)))
#define nor4(a0,a1,a2,a3) (!((a0) || (a1) || (a2) || (a3)))
#define nor5(a0,a1,a2,a3,a4) (!((a0) || (a1) || (a2) || (a3) || (a4)))
#define xor2(a0,a1) ((a0 && (!a1)) || ((!a0) && a1))